drop table if exists jms_dm.dm_tms_trunk_oper_summary_dt;
CREATE EXTERNAL TABLE jms_dm.dm_tms_trunk_oper_summary_dt(
      `shipment_no` string COMMENT '任务编号',
      `shipment_name` string COMMENT '任务名称',
      `setout_arrive_sitename` string COMMENT '任务拆分名称',
      `setout_sitename` string COMMENT '发出中心',
      `setout_sitecode` string COMMENT '发出中心编码',
      `arrive_sitename` string COMMENT '到达中心',
      `arrive_sitecode` string COMMENT '到达中心编码',
      `tickets` int COMMENT '票数',
      `packages` int COMMENT '袋数',
      `bulks` int COMMENT '散件数',
      `pkg_bulks` int COMMENT '袋数与散件数之和',
      `min_operation_duration` double COMMENT '最小操作时长',
      `max_operation_duration` double COMMENT '最大操作时长',
    `avg_operation_duration` double COMMENT '平均操作时长')
    COMMENT '干线车辆操作时效汇总表'
    PARTITIONED BY (
        `dt` string COMMENT '到车日期 (yyyy-mm-dd)')
    stored as parquet
    LOCATION
        'hdfs://uat-bg-hdp/dw/hive/jms_dm.db/external/dm_tms_trunk_oper_summary_dt'
msck repair table jms_dm.dm_tms_trunk_oper_summary_dt;